package com.axjy.dao;

import com.axjy.controller.dto.UserDto;
import com.axjy.pojo.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * Created by asus on 2017/9/18.
 */
public interface UserMapper extends BaseMapper<User>{


    public List<User> search(@Param("offset") Integer offset,@Param("limit") Integer limit,@Param("name") String columnName, @Param("value")String columnValue);


    public Integer getTotal(@Param("name") String columnName, @Param("value")String columnValue);

    public void updateRole(@Param("id") Integer uid,@Param("roleId") Integer roleId);

    public User searchUser(@Param("name")String name,@Param("pwd")String pwd);


    public List<User> searchByRole(Integer rid);

    public List<User> searchByDyna(@Param("offset") Integer offset,@Param("limit") Integer limit,@Param("dto") UserDto userDto);

    public Integer getTotalByDyna(@Param("dto")UserDto userDto);
}
